<template>
  <div>
    <div class="title font14 ma30-15">
      <p>基本信息</p>
    </div>
    <el-form
      :model="ruleForm"
      ref="ruleForm"
      label-width="100px"
      class="demo-ruleForm mt20"
    >
      <!-- 基本信息 -->
      <div class="pa15 bor7 details">
        <div class="clearfix">
          <div class="fr details-but">
            <el-button type="primary">返回</el-button>
          </div>
        </div>

        <el-form-item label="活动标题" prop="name" class="font12" required>
          <el-input v-model="ruleForm.name"></el-input>
        </el-form-item>

        <el-form-item label="活动海报" prop="img" class="font12" required>
          <img src="../../img/2.jpg" alt />
        </el-form-item>

        <el-form-item label="活动类型" required class="wid50 font12">
          <el-form-item prop="region1">
            <el-select v-model="ruleForm.region2" placeholder="户外旅游">
              <el-option label="室内活动" value="meiguo"></el-option>
            </el-select>
          </el-form-item>
        </el-form-item>
      </div>
      <div class="title font14 ma30-15">
        <p>参加会员</p>
      </div>
      <!-- 基本信息 -->
      <div class="pa15 bor7 details-fix">
        <div class="details-fix-duv mt20">
          <el-row :gutter="20">
            <el-col :span="5">
              <div class="grid-content bg-purple">
                <div>
                  <img src="../../img/1.jpg" alt />
                </div>
                <p class="font12">Jason</p>
                <p class="font12">活动发起人</p>
              </div>
            </el-col>
            <el-col :span="5">
              <div class="grid-content bg-purple">
                <div>
                  <img src="../../img/1.jpg" alt />
                </div>
                <p class="font12">Jason</p>
                <p class="font12">活动发起人</p>
              </div>
            </el-col>
            <el-col :span="5">
              <div class="grid-content bg-purple">
                <div>
                  <img src="../../img/1.jpg" alt />
                </div>
                <p class="font12">Jason</p>
                <p class="font12">活动发起人</p>
              </div>
            </el-col>
            <el-col :span="5">
              <div class="grid-content bg-purple">
                <div>
                  <img src="../../img/1.jpg" alt />
                </div>
                <p class="font12">Jason</p>
                <p class="font12">活动发起人</p>
              </div>
            </el-col>
            <el-col :span="5">
              <div class="grid-content bg-purple">
                <div>
                  <img src="../../img/1.jpg" alt />
                </div>
                <p class="font12">Jason</p>
                <p class="font12">活动发起人</p>
              </div>
            </el-col>
            <el-col :span="5">
              <div class="grid-content bg-purple">
                <div>
                  <img src="../../img/1.jpg" alt />
                </div>
                <p class="font12">Jason</p>
                <p class="font12">活动发起人</p>
              </div>
            </el-col>
            <el-col :span="5">
              <div class="grid-content bg-purple">
                <div>
                  <img src="../../img/1.jpg" alt />
                </div>
                <p class="font12">Jason</p>
                <p class="font12">活动发起人</p>
              </div>
            </el-col>
            <el-col :span="5">
              <div class="grid-content bg-purple">
                <div>
                  <img src="../../img/1.jpg" alt />
                </div>
                <p class="font12">Jason</p>
                <p class="font12">活动发起人</p>
              </div>
            </el-col>
            <el-col :span="5">
              <div class="grid-content bg-purple">
                <div>
                  <img src="../../img/1.jpg" alt />
                </div>
                <p class="font12">Jason</p>
                <p class="font12">活动发起人</p>
              </div>
            </el-col>
            <el-col :span="5">
              <div class="grid-content bg-purple">
                <div>
                  <img src="../../img/1.jpg" alt />
                </div>
                <p class="font12">Jason</p>
                <p class="font12">活动发起人</p>
              </div>
            </el-col>
          </el-row>
        </div>
      </div>
      <!--  -->
      <div class="title font14 ma30-15">
        <p>活动内容</p>
      </div>
      <!-- 活动内容 -->
      <div class="pa15 bor7 details-fng">
        <div class="quill-box">
          <el-form-item prop="content" >
            <quill-editor
              v-model="ruleForm.content"
              :options="editorOption"
              ref="content"
            ></quill-editor>
          </el-form-item>
        </div>
        <div class="ta mt20">
          <el-button type="primary">保存团队信息</el-button>
        </div>
      </div>
      <!-- end -->
    </el-form>
  </div>
</template>



<style scoped>
/* .el-form-item__content{
  width: 50%;
} */
.ql-snow .ql-color-picker .ql-picker-label svg,
.ql-snow .ql-icon-picker .ql-picker-label svg {
  position: relative;
  top: 0;
}
.ql-snow .ql-picker-label::before {
  top: 0;
}
html {
  height: 100% !important;
  overflow-y: hidden !important;
}
.details {
}
/* .details .demo-ruleForm > div:nth-of-type(2) {
  width: 50%;
} */
.el-form-item__label {
}
.details .demo-ruleForm > div label {
  text-align: left;
  font-size: 0.75rem;
}
.details .line {
  text-align: center;
}
.el-select {
  width: 100%;
}
.details .el-col-20 {
  width: 82.33333%;
  margin-left: 1%;
}
.wid50 {
  width: 50%;
}
.details-fix .el-button {
  padding: 0.3125rem 0.625rem;
  font-size: 0.875rem;
}
.details-fix .el-button--success {
  background: #19a15f;
}
.el-form-item > label {
  text-align: left !important;
}
.details .font12 label {
  text-align: left;
  font-size: 0.75rem;
}
.details-fix-duv .bg-purple {
  border: 1px solid #d8d8d8;
  text-align: center;
  color: #b2b2b2;
  padding: 3rem 0;
}
.details-fix-duv .bg-purple:hover {
  border-color: #4285f4;
}
.details-fix-duv .el-col-5 {
  width: 20%;
  margin-bottom: 1.25rem;
}
.details-fix-duv .bg-purple p:nth-of-type(1) {
  color: #545556;
  margin: 1.25rem 0 0.625rem;
}
.details-fix-duv .bg-purple img {
  width: 6.375rem;
  object-fit: cover;
}
.quill-box .quill-editor {
  overflow: hidden;
  font-style: initial;
}
.ql-toolbar.ql-snow + .ql-container.ql-snow {
  height: 100% !important;
  position: relative;
  /* min-height: 14.0625rem;
  font-style: initial; */
}
.ql-editor {
}
.details-but .el-button {
  padding: 0.75rem 2rem;
}
</style>

<script>
import { quillEditor, Quill } from "vue-quill-editor";
const toolbarOptions = [
  ["bold", "italic", "underline", "strike"],
  ["blockquote", "code-block"],
  [{ list: "ordered" }, { list: "bullet" }],
  [{ indent: "-1" }, { indent: "+1" }],
  [{ color: [] }, { background: [] }],
  [{ align: [] }],
  ["link", "image"],
  ["clean"],
  [{ size: ["small", false, "large", "huge"] }],
  [{ header: [1, 2, 3, 4, 5, 6, false] }],
  [{ font: [] }],
];

export default {
  data() {
    return {
      ruleForm: {
        name: "我是IT人沙龙第十期：智能产业服务时代的新十年",
        region: "中国",
      },
      methods: {
        onEditorReady(editor) {
          // 准备编辑器
        },
        onEditorBlur() {}, // 失去焦点事件
        onEditorFocus() {}, // 获得焦点事件
        onEditorChange() {}, // 内容改变事件
      },
      editorOption: {
        placeholder: "内容编辑",
        modules: {
          toolbar: {
            container: toolbarOptions,
            // ...
          },
        },
      },
    };
  },
  components: {
    "quill-editor": quillEditor,
  },
};
</script>
